Skip to content

OCPEDGE-2746: Add MutableTopology feature gated infra spec.controlPlaneTopology#2891

Open
jeff-roche wants to merge 1 commit into
openshift:masterfrom
jeff-roche:controlPlaneTopologySpec
Open

OCPEDGE-2746: Add MutableTopology feature gated infra spec.controlPlaneTopology#2891
jeff-roche wants to merge 1 commit into
openshift:masterfrom
jeff-roche:controlPlaneTopologySpec

Conversation

@jeff-roche

Copy link
Copy Markdown

Utilizes the MutableTopology feature gate which enables spec.controlPlaneTopology on the Infrastructure resource, allowing cluster topology to be set to HighlyAvailable or SingleReplica.

CRD manifests are now split per cluster profile (Hypershift, SelfManagedHA) so the field is only present in the appropriate profile/feature-set combinations.

Includes integration tests verifying:

  • Accepted values when the gate is enabled (MutableTopology.yaml)
  • Field pruning when the gate is disabled (AAA_ungated.yaml)

Implements API changes needed for enhancements#2008

Introduce the MutableTopology feature gate which enables
spec.controlPlaneTopology on the Infrastructure resource, allowing
cluster topology to be set to HighlyAvailable or SingleReplica.

CRD manifests are now split per cluster profile (Hypershift,
SelfManagedHA) so the field is only present in the appropriate
profile/feature-set combinations.

Includes integration tests verifying:
- Accepted values when the gate is enabled (MutableTopology.yaml)
- Field pruning when the gate is disabled (AAA_ungated.yaml)

Assisted-by: Claude <noreply@anthropic.com>
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jun 15, 2026
@openshift-ci-robot

openshift-ci-robot commented Jun 15, 2026

Copy link
Copy Markdown

@jeff-roche: This pull request references OCPEDGE-2746 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "5.0.0" version, but no target version was set.

Details

In response to this:

Utilizes the MutableTopology feature gate which enables spec.controlPlaneTopology on the Infrastructure resource, allowing cluster topology to be set to HighlyAvailable or SingleReplica.

CRD manifests are now split per cluster profile (Hypershift, SelfManagedHA) so the field is only present in the appropriate profile/feature-set combinations.

Includes integration tests verifying:

  • Accepted values when the gate is enabled (MutableTopology.yaml)
  • Field pruning when the gate is disabled (AAA_ungated.yaml)

Implements API changes needed for enhancements#2008

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci

openshift-ci Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Hello @jeff-roche! Some important instructions when contributing to openshift/api:
API design plays an important part in the user experience of OpenShift and as such API PRs are subject to a high level of scrutiny to ensure they follow our best practices. If you haven't already done so, please review the OpenShift API Conventions and ensure that your proposed changes are compliant. Following these conventions will help expedite the api review process for your PR.

@coderabbitai

coderabbitai Bot commented Jun 15, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Enterprise

Run ID: ef8f7a2a-3fe1-41c7-a222-c15b20aad447

📥 Commits

Reviewing files that changed from the base of the PR and between 261e3a0 and 4fa8a9b.

⛔ Files ignored due to path filters (15)
  • config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Hypershift-CustomNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-Hypershift-DevPreviewNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-SelfManagedHA-CustomNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • config/v1/zz_generated.crd-manifests/0000_10_config-operator_01_infrastructures-SelfManagedHA-DevPreviewNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • config/v1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/zz_generated*
  • config/v1/zz_generated.featuregated-crd-manifests/infrastructures.config.openshift.io/MutableTopology.yaml is excluded by !**/zz_generated.featuregated-crd-manifests/**
  • config/v1/zz_generated.swagger_doc_generated.go is excluded by !**/zz_generated*
  • machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Hypershift-CustomNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-Hypershift-DevPreviewNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-SelfManagedHA-CustomNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • machineconfiguration/v1/zz_generated.crd-manifests/0000_80_machine-config_01_controllerconfigs-SelfManagedHA-DevPreviewNoUpgrade.crd.yaml is excluded by !**/zz_generated.crd-manifests/*
  • machineconfiguration/v1/zz_generated.featuregated-crd-manifests.yaml is excluded by !**/zz_generated*
  • machineconfiguration/v1/zz_generated.featuregated-crd-manifests/controllerconfigs.machineconfiguration.openshift.io/MutableTopology.yaml is excluded by !**/zz_generated.featuregated-crd-manifests/**
  • openapi/generated_openapi/zz_generated.openapi.go is excluded by !openapi/**, !**/zz_generated*
  • openapi/openapi.json is excluded by !openapi/**
📒 Files selected for processing (12)
  • config/v1/tests/infrastructures.config.openshift.io/AAA_ungated.yaml
  • config/v1/tests/infrastructures.config.openshift.io/MutableTopology.yaml
  • config/v1/types_infrastructure.go
  • machineconfiguration/v1/tests/controllerconfigs.machineconfiguration.openshift.io/MutableTopology.yaml
  • payload-manifests/crds/0000_10_config-operator_01_infrastructures-Hypershift-CustomNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_10_config-operator_01_infrastructures-Hypershift-DevPreviewNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_10_config-operator_01_infrastructures-SelfManagedHA-CustomNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_10_config-operator_01_infrastructures-SelfManagedHA-DevPreviewNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Hypershift-CustomNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Hypershift-DevPreviewNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-SelfManagedHA-CustomNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-SelfManagedHA-DevPreviewNoUpgrade.crd.yaml
💤 Files with no reviewable changes (2)
  • payload-manifests/crds/0000_80_machine-config_01_controllerconfigs-Hypershift-DevPreviewNoUpgrade.crd.yaml
  • payload-manifests/crds/0000_10_config-operator_01_infrastructures-Hypershift-DevPreviewNoUpgrade.crd.yaml

📝 Walkthrough

Walkthrough

The PR adds an optional ControlPlaneTopology field of type TopologyMode to InfrastructureSpec in config/v1/types_infrastructure.go, gated by the MutableTopology OpenShift feature gate with enum validation for HighlyAvailable and SingleReplica. New YAML test suites are added for the Infrastructure CRD covering both ungated pruning behavior (field stripped when gate is off) and gated create/update scenarios including valid values, topology transitions, and invalid-value error assertions. A ControllerConfig test fixture is added for the same feature gate. Two Hypershift DevPreviewNoUpgrade CRD payload manifests have the include.release.openshift.io/self-managed-high-availability: "true" annotation removed.

Suggested reviewers

  • everettraven
  • JoelSpeed
🚥 Pre-merge checks | ✅ 15
✅ Passed checks (15 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: adding the MutableTopology feature-gated controlPlaneTopology field to the Infrastructure spec.
Description check ✅ Passed The description clearly explains the changes: enabling spec.controlPlaneTopology via the MutableTopology feature gate, splitting CRD manifests by cluster profile, and including integration tests for both enabled and disabled states.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed All 14 Ginkgo test names added in the PR are stable and deterministic, with no dynamic information, generated suffixes, timestamps, or identifiers that could vary between runs.
Test Structure And Quality ✅ Passed The test fixtures follow excellent quality standards: each test has single responsibility (distinct names for one behavior), proper setup/cleanup through Ginkgo harness (CRD install/uninstall in Be...
Microshift Test Compatibility ✅ Passed PR adds CRD API schema validation test configs (YAML), not Ginkgo e2e tests. Custom check for MicroShift compatibility applies only to Ginkgo test definitions.
Single Node Openshift (Sno) Test Compatibility ✅ Passed No Ginkgo e2e tests were added in this PR. The changes consist solely of YAML-based API validation test fixtures for CRD behavior and type definitions, not executable Ginkgo test code.
Topology-Aware Scheduling Compatibility ✅ Passed PR adds only API type definitions and test configurations for MutableTopology feature gate. No deployment manifests, operator code, or controllers with scheduling constraints are introduced. Change...
Ote Binary Stdout Contract ✅ Passed PR contains only YAML test fixtures, CRD manifest changes, and Go type definitions with no process-level code that writes to stdout.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed PR adds no Ginkgo e2e tests - only CRD validation fixtures, Go type definitions, and CRD manifests. Check is not applicable.
No-Weak-Crypto ✅ Passed PR contains no weak cryptography (MD5/SHA1/DES/RC4/3DES/Blowfish/ECB), custom crypto implementations, or non-constant-time secret comparisons. Changes are limited to topology configuration fields,...
Container-Privileges ✅ Passed The PR contains only type definitions, CRD schemas, and API test fixtures—not container deployment manifests. No privileged container configurations are present.
No-Sensitive-Data-In-Logs ✅ Passed No logging of sensitive data detected. PR adds type definitions, test fixtures, and CRD schemas with no logging code or sensitive data exposure.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.12.2)

Error: build linters: unable to load custom analyzer "kubeapilinter": tools/_output/bin/kube-api-linter.so, plugin: not implemented
The command is terminated due to an error: build linters: unable to load custom analyzer "kubeapilinter": tools/_output/bin/kube-api-linter.so, plugin: not implemented


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci openshift-ci Bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jun 15, 2026
@openshift-ci openshift-ci Bot requested review from JoelSpeed and jkyros June 15, 2026 18:03
@openshift-ci

openshift-ci Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign deads2k for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jeff-roche

Copy link
Copy Markdown
Author

The linter failure doesn't make much sense to me, enum should be a better validator than string length.

Comment thread config/v1/types_infrastructure.go
@openshift-ci

openshift-ci Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

@jeff-roche: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/lint 4fa8a9b link true /test lint

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants